<?php if (!defined('THINK_PATH')) exit(); /*a:2:{s:101:"D:\wwwroot\schoolnx.nxers.com1\schoolnx.nxers.com\public/../application/admin\view\exam\analysis.html";i:1585464872;s:84:"D:\wwwroot\schoolnx.nxers.com1\schoolnx.nxers.com\application\admin\view\iframe.html";i:1598842652;}*/ ?>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <title>后台管理系统</title>
    <link rel="stylesheet" href="/static/libs/layui/css/layui.css">
    <link rel="stylesheet" href="/static/default/css/base.css">
    <link rel="stylesheet" href="/static/default/css/fonts.css">
    <!--引入CSS-->
    <link rel="stylesheet" type="text/css" href="/static/webuploader/webuploader.css">
    
<style type="text/css">
    .layui-card .layui-card-body .layui-form{padding-top: 0px !important; }
    .layui-card {box-shadow: none;}
</style>

</head>
<body class="layui-layout-iframe">

<div class="layui-card">
    <div class="layui-card-header">
      成绩统计分析-<?php echo get_exam_title($paperinfo['id']); ?>
    </div>
    <div class="layui-card-body">
        <table id="analysisTable" class="commontable" style="margin-left:15px;width:97%">
            <tbody><tr>
                <td class="title" id="sAttendTotalNum">参加人数<br><br><span class="analysis" id="attendNum"><?php echo $count; ?></span></td>
                <td class="title">通过人数<br><br><span class="analysis" id="passNum"><?php echo $passNum; ?></span></td>
                <td class="title">未通过人数<br><br><span class="analysis" id="nonPassNum"><?php echo $noPassNum; ?></span></td>
                <td class="title">通过率<br><br><span class="analysis" id="passRate"><?php echo $pass; ?></span>%</td>
                <td class="title">最高分<br><br><span class="analysis" id="maxScore"><?php echo $maxScore; ?></span></td>
                <td class="title">最低分<br><br><span class="analysis" id="minScore"><?php echo $minScore; ?></span></td>
                <td class="title">平均分<br><br><span class="analysis" id="avgScore"><?php echo $avgScore; ?></span></td>
            </tr>
            </tbody>
        </table>
        <input type="hidden" id="eid" value="<?php echo $paperinfo['id']; ?>">
        <table class="layui-hide" id="analysis"></table>
    </div>
    <div class="layui-row  learn-bottom">
        <a href="<?php echo url('admin/exam/export',['eid'=>$paperinfo['id']]); ?>" class="layui-btn layui-btn-primary"><i class="fa fa-file-excel-o"></i> 导出成绩</a>
    </div>
</div>

<script src="/static/libs/layui/layui.all.js"></script>
<script src="/static/libs/common/jquery.min.js"></script>
<script src="/static/libs/common/common.js"></script>
<script src="https://cdn.bootcss.com/stickyNavbar.js/1.3.5/jquery.stickyNavbar.min.js"></script>
<link rel="stylesheet" href="//cdn.bootcss.com/bootstrap/3.3.4/css/bootstrap.min.css">

<script>
    layui.use('table', function(){
        var table = layui.table;
        var eid=$('#eid').val();
        table.render({
            elem: '#analysis'
            ,url:'/admin/exam/useranalysis/id/'+eid
            ,page: {
                layout: ['limit', 'count', 'prev', 'page', 'next', 'skip']
                ,groups: 1 //只显示 1 个连续页码
                ,first: false //不显示首页
                ,last: false //不显示尾页
            }
            ,cols: [[
                {field:'username', width:152, title: '姓名'}
                ,{field:'totalscore', width:125, title: '试卷总分'}
                ,{field:'passscore', width:125, title: '通过分数'}
                ,{field:'score', width:120, title: '考试成绩', sort: true}
                ,{field:'ispass', width:130,title: '是否通过考试'}
                ,{field:'addtime', width:190, title: '交卷时间', sort: true}
                ,{field:'sort', width:90, title: '排名', sort: true}
            ]]

        });
    });
</script>

</body>
</html>
